package com.gxk.res;

import java.util.ArrayList;
import java.util.List;
import java.util.Random;

import com.badlogic.gdx.graphics.g2d.Animation;

public class AnimationFactory implements IResource {
	private static List<Animation> birdAnimations = new ArrayList<Animation>();

	private static Animation bird0 = new Animation(0.085f,
			ATLAS.findRegions("bird0"));
	private static Animation bird1 = new Animation(0.085f,
			ATLAS.findRegions("bird1"));
	private static Animation bird2 = new Animation(0.085f,
			ATLAS.findRegions("bird2"));

	static {
		birdAnimations.add(bird0);
		birdAnimations.add(bird1);
		birdAnimations.add(bird2);
	}

	public static Animation getBirdAnimation() {
		return birdAnimations.get(new Random().nextInt(3));
	}
}
